Context Rules

context_001

phase_4 error indent

This rule checks the indent of the context keyword.

Violation

context c1 is

library ieee;

Fix

context c1 is

  library ieee;

context_002

phase_2 error whitespace

This rule checks for a single space between the context keyword and the context identifier.

Refer to Configuring Whitespace Rules for options on changing the number of whitespaces..

Violation

context   c1 is

Fix

context c1 is

context_003

phase_3 error blank_line

This rule checks for blank lines or comments above the context keyword.

Refer to Configuring Previous Line Rules for more information.

The default style is no_code.

Violation

library ieee;
context c1 is

--Some Comment
context c1 is

Fix

library ieee;

context c1 is

--Some Comment
context c1 is

context_004

phase_6 error case case_keyword

This rule checks the context keyword has proper case.

Refer to Configuring Uppercase and Lowercase Rules for more information.

Violation

CONTEXT c1 is

Fix

context c1 is

context_005

phase_1 error structure

This rule checks the context identifier is on the same line as the context keyword.

Violation

context
c1
  is

Fix

context c1
  is

context_006

phase_1 error structure

This rule checks the is keyword is on the same line as the context identifier.

Violation

context c1
  is

Fix

context c1 is

context_007

phase_1 error structure

This rule checks for code after the is keyword.

Violation

context c1 is -- Comments are allowed

context c1 is library ieee; -- This is not allowed

Fix

context c1 is -- Comments are allowed

context c1 is
  library ieee; -- This is not allowed

context_008

phase_1 error structure

This rule checks the end keyword is on its own line.

Violation

context c1 is library ieee; end context c1;

context c1 is library ieee; end;

Fix

context c1 is library ieee;
end context c1;

context c1 is library ieee;
end;

context_009

phase_1 error structure

This rule checks the context keyword is on the same line as the end context keyword.

Violation

end
context c1;

Fix

end context
  c1;

context_010

phase_1 error structure

This rule checks the context identifier is on the same line as the end context keyword.

Violation

end context
c1;

Fix

end context c1;

context_011

phase_1 error structure

This rule checks the semicolon is on the same line as the end keyword.

Violation

end
;

end context
;

end context c1
;

Fix

end;

end context;

end context c1;

context_012

phase_6 error case case_name

This rule checks the context identifier has proper case in the context declaration.

Refer to Configuring Uppercase and Lowercase Rules for more information.

Violation

context C1 is

Fix

context c1 is

context_013

phase_6 error case case_keyword

This rule checks the is keyword has proper case in the context declaration.

Refer to Configuring Uppercase and Lowercase Rules for more information.

Violation

context c1 IS

Fix

context c1 is

context_014

phase_6 error case case_keyword

This rule checks the end keyword has proper case.

Refer to Configuring Uppercase and Lowercase Rules for more information.

Violation

End;

END context;

Fix

end;

end context;

context_015

phase_6 error case case_keyword

This rule checks the context keyword has proper case in the end context declaration.

Refer to Configuring Uppercase and Lowercase Rules for more information.

Violation

end CONTEXT;

Fix

end context;

context_016

phase_6 error case case_name

This rule checks the context identifier has proper case in the end context declaration.

Refer to Configuring Uppercase and Lowercase Rules for more information.

Violation

end context C1;

Fix

end context c1;

context_017

phase_2 error whitespace

This rule checks for a single space between the context identifier and the is keyword.

Refer to Configuring Whitespace Rules for options on changing the number of whitespaces..

Violation

context c1    is

Fix

context c1 is

context_018

phase_2 error whitespace

This rule checks for a single space between the end keyword and the context keyword.

Refer to Configuring Whitespace Rules for options on changing the number of whitespaces..

Violation

end;

end   context;

Fix

end;

end context;

context_019

phase_2 error whitespace

This rule checks for a single space between the context keyword and the context identifier.

Refer to Configuring Whitespace Rules for options on changing the number of whitespaces..

Violation

end context;

end context    c1;

Fix

end context;

end context c1;

context_020

phase_4 error indent

This rule checks the indent of the end keyword.

Violation

context c1 is
   end context c1;

Fix

context c1 is
end context c1;

context_021

phase_1 error structure structure_optional

This rule checks for the keyword context in the end context statement.

Refer to Configuring Optional Items for more information.

Violation

end c1;

end;

Fix

end context c1;

end context;

context_022

phase_1 error structure structure_optional

This rule checks for the context name in the end context statement.

Refer to Configuring Optional Items for more information.

Violation

end context;

Fix

end context c1;

context_023

phase_3 error blank_line

This rule adds a blank line below the is keyword.

Refer to Configuring Blank Lines for more information.

Violation

context c1 is
  library IEEE;

Fix

context c1 is

  library IEEE;

context_024

phase_3 error blank_line

This rule checks for blank lines or comments above the end keyword.

Refer to Configuring Blank Lines for more information.

The default style is no_code.

Violation

  use ieee.std_logic_1164.all;
end context;

Fix

  use ieee.std_logic_1164.all;

end context;

context_025

phase_3 error blank_line

This rule adds a blank line below the context semicolon.

Refer to Configuring Blank Lines for more information.

Violation

end context;
entity fifo is

Fix

end context;

entity fifo is

context_026

The function of this rule has been moved to whitespace_200.

context_027

The function of this rule has been moved to whitespace_200.

context_028

Note

This rule has not been implemented yet.

This rule checks for alignment of inline comments in the context declaration.

Refer to Configuring Keyword Alignment Rules for information on changing the configurations.

Violation

context c1 is                       -- Some comment
  library ieee;                        -- Other comment
    use ieee.std_logic_1164.all;   -- Comment 3
end context c1;  -- Comment 4

Fix

context c1 is                    -- Some comment
  library ieee;                  -- Other comment
    use ieee.std_logic_1164.all; -- Comment 3
end context c1;                  -- Comment 4