Why does syntax highlighting color some functions blue?

Does anyone know why syntax highlighting colors some functions (ex. library, require, return) blue?

I'm trying to understand where these blue functions fit in with my understanding of RStudio's (default) syntax highlighting... :thinking:

Thanks!

If they aren't technically reserved words, they perhaps should be ...

Hmm, they don't seem to be. If I run "?reserved", the list of reserved words that I get is:

  • if
  • else
  • repeat
  • while
  • function
  • for
  • in
  • next
  • break
  • TRUE
  • FALSE
  • NULL
  • Inf
  • NaN
  • NA
  • NA_integer_
  • NA_real_
  • NA_complex_
  • NA_character_

Perhaps there is a different/longer list of reserved words?

Meanwhile, I'm seeing all of these functions showing up highlighted blue:

I didnt say that they are, I was pointing out that pain will follow any programmer who doesnt treat them as such.
Im sorry if it doesnt help you, but I found it an amusing thought.

Apologies for any confusion -- it can be difficult to both read and relay tone via posts.

Absolutely! It would be painful indeed :laughing:

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.