From 5559bcca67f488cbf0836b4ccd25bf4751657210 Mon Sep 17 00:00:00 2001 From: Maxime Mangel Date: Tue, 26 Apr 2022 16:36:37 +0200 Subject: [PATCH] Add support for F# open static class --- lexers/embedded/fsharp.xml | 2 +- .../fsharp/fsharp_open_static_class.actual | 4 ++++ .../fsharp/fsharp_open_static_class.expected | 16 ++++++++++++++++ 3 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 lexers/testdata/fsharp/fsharp_open_static_class.actual create mode 100644 lexers/testdata/fsharp/fsharp_open_static_class.expected diff --git a/lexers/embedded/fsharp.xml b/lexers/embedded/fsharp.xml index f60897977..e1c19ffb4 100644 --- a/lexers/embedded/fsharp.xml +++ b/lexers/embedded/fsharp.xml @@ -133,7 +133,7 @@ - + diff --git a/lexers/testdata/fsharp/fsharp_open_static_class.actual b/lexers/testdata/fsharp/fsharp_open_static_class.actual new file mode 100644 index 000000000..00bc4b742 --- /dev/null +++ b/lexers/testdata/fsharp/fsharp_open_static_class.actual @@ -0,0 +1,4 @@ +open type System.Math + +module A = + open type System.Math diff --git a/lexers/testdata/fsharp/fsharp_open_static_class.expected b/lexers/testdata/fsharp/fsharp_open_static_class.expected new file mode 100644 index 000000000..1c58e26b0 --- /dev/null +++ b/lexers/testdata/fsharp/fsharp_open_static_class.expected @@ -0,0 +1,16 @@ +[ + {"type":"Keyword","value":"open type"}, + {"type":"Text","value":" "}, + {"type":"NameNamespace","value":"System.Math"}, + {"type":"Text","value":"\n\n"}, + {"type":"Keyword","value":"module"}, + {"type":"Text","value":" "}, + {"type":"NameNamespace","value":"A"}, + {"type":"Text","value":" "}, + {"type":"Operator","value":"="}, + {"type":"Text","value":"\n "}, + {"type":"Keyword","value":"open type"}, + {"type":"Text","value":" "}, + {"type":"NameNamespace","value":"System.Math"}, + {"type":"Text","value":"\n"} +]