Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

indentation in module with tasks #3

Open
kazarynau opened this issue Mar 29, 2019 · 0 comments
Open

indentation in module with tasks #3

kazarynau opened this issue Mar 29, 2019 · 0 comments

Comments

@kazarynau
Copy link

kazarynau commented Mar 29, 2019

Could you please check the formatting of the following code:
module abc;

localparam CLK_PRD = 10;

typedef enum int unsigned
{
    TST_0,
    TST_1,
    TST_2
} tst_e;
tst_e                  tst ;


///////////////////////////////////////////////////////////////////
// Tasks
///////////////////////////////////////////////////////////////////
// Write register
task automatic write_reg(
    input avmm_addr_t  ti_address,
    input avmm_data_t  ti_value);
    
endtask : write_reg

// Read register
task automatic read_reg(
    input  avmm_addr_t  ti_address,
    output avmm_data_t  to_value);
    
endtask : read_reg

endmodule

I have the following result:
module abc; localparam CLK_PRD = 10; typedef enum int unsigned { TST_0, TST_1, TST_2 } tst_e; tst_e tst ; task automatic write_reg(input avmm_addr_t ti_address, input avmm_data_t ti_value);

    endtask : write_reg
    
    // Read register
    task automatic read_reg(
        input  avmm_addr_t  ti_address,
        output avmm_data_t  to_value);
        
        endtask : read_reg
        
        endmodule

`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant