Skip to content

Accessing Variables before their declaration in Fully_connected_layer #11

@faayez-10xe

Description

@faayez-10xe

Issue Title
Issue Title: Accessing Variables before their declaration
Problem Description
During the testing of Fully Connected layer, there comes an error in module Fully_connected_layer. In this module, two variables, named tempv and tempf, are being accessed before their declaration.

Expected Behavior
This code will produce compilation errors and will not be compiled and run.

Reasons Behind the Compilation error Error
Error is due to accessing two variables, named tempv and tempf, before their declaration.

In file Fully_connected_layer.v, in initial block, tempv and tempf are assigned with value zero. If we loot at the code above these lines, there is no declaration of these variables. These two variable are declared before always block which is written at the end of this code.

Proposed Solution
To resolve this issue, cut this line which is placed just before always block and paste it before initial block.

reg tempv,tempf;

image

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions