1. Georg Brandl
  2. pygments-main
  3. Pull requests

Pull requests

#288 Merged
Repository
jstvz
Branch
default
Repository
birkenfeld
Branch
default

Issue #412: Add built-in functions to SLexer

Author
  1. James Estevez
Reviewers
Description

Currently, the S-plus/R lexer does not recognize:

  • any built-in functions,
  • any data structures,
  • all built-in constants,
  • exponents on floating points with decimals, but no mantissa

This update to math.py adds a list of only those functions contained within package:base, output from R with via the builtins(TRUE) function. Keywords for Keyword.Constant, Keyword.Namespace, and Keyword.Type were manually subsetted from the resulting list. This is the approach used by the Mathematica and Numpy lexers.

The update to test.R adds a sample of the builtin functions, data structures, and namespace functions, along with an example of a floating point with a decimal, but no fractional part.

Comments (1)