# Make sure everything imports the options, and all Instance/Argument/Hint are qualified.
# Make sure everything imports the options, and all Instance/Argument/Hint are qualified.
$(SHOW)"Performing some style checks..."
$(HIDE)forFILEin$(VFILES);do\
$(HIDE)forFILEin$(VFILES);do\
if ! fgrep -q 'From iris.prelude Require Import options.' "$$FILE"; then echo "ERROR:$$FILE does not import 'options'."; echo; exit 1; fi ; \
if ! fgrep -q 'From iris.prelude Require Import options.' "$$FILE"; then echo "ERROR:$$FILE does not import 'options'."; echo; exit 1; fi ; \
if egrep '^\s*(Instance|Arguments|Remove|Hint(Extern|Constructors|Resolve|Immediate|Mode|Opaque|Transparent|Unfold))\s' "$$FILE"; then echo "ERROR: $$FILE contains unqualified 'Instance'/'Arguments'/'Hint' (see above)."; echo "Please add 'Global' or 'Local' as appropriate."; echo; exit 1; fi \
if egrep '^\s*(Instance|Arguments|Remove|Hint\s+(Extern|Constructors|Resolve|Immediate|Mode|Opaque|Transparent|Unfold)|(Open|Close)\s+Scope)\s' "$$FILE"; then echo "ERROR: $$FILE contains unqualified 'Instance'/'Arguments'/'Hint'/'Scope' (see above)."; echo "Please add 'Global' or 'Local' as appropriate."; echo; exit 1; fi \
done
done
# Make sure main Iris does not import other Iris packages.
# Make sure main Iris does not import other Iris packages.
$(HIDE)if egrep 'iris\.(heap_lang|deprecated|staging)' --include "*.v" -R iris; then echo "ERROR:Iris may not import modules from other Iris packages (see above for violations)."; echo; exit 1; fi
$(HIDE)if egrep 'iris\.(heap_lang|deprecated|staging)' --include "*.v" -R iris; then echo "ERROR:Iris may not import modules from other Iris packages (see above for violations)."; echo; exit 1; fi