nim-lang / nim-mode

An emacs major mode for the Nim programming language
138 stars 46 forks source link

nimsuggest-mode: Invalid face reference: face #161

Closed kaushalmodi closed 7 years ago

kaushalmodi commented 7 years ago

For this simple code where I was experimenting with noSideEffect:

proc sum(x, y:int): int {. noSideEffect .} =
  echo x # causes side effect
  x + y

echo sum(2,3)

and with nimsuggest-mode enabled and flycheck-mode disabled, I get this in the *Messages* buffer:

Invalid face reference: face

each time, I place the point on

proc sum(x, y:int): int {. noSideEffect .} =


kaushalmodi commented 7 years ago

I think it has to do with the pragma.. if I remove the pragma from that first line, the invalid face error goes away:

proc sum(x, y:int): int =
yuutayamada commented 7 years ago

I'm not sure this is related to #166, but I could only reproduce on nimscript-mode and I think I fixed #166. Please re-open if this issue is still remaining.