I'm using the Mono compiler. When I tried to compile this:
using static System.Globalization.CharUnicodeInfo;
using static System.Globalization.UnicodeCategory;
namespace AS3Kit.Lexical
{
static class Validator
{
static bool TestCategory(UnicodeCategory cat, int cp)
{ return CharUnicodeInfo.GetUnicodeCategory(cp) == cat; }
// ...
}
}
Error occurred
D: \ hydroper \ local \ work \ cs \ AS3Kit> mcs -recurse: source / *. cs -out: AS3Kit.exe source \ Lexical \ Validator.cs (8,28): error CS0246: The type or namespace name
Uni codeCategory' could not be found. Are you missing
System.Globalization 'using d irective? Compilation failed: 1 error (s), 0 warnings
What you're saying, type UnicodeCategory
does not exist. However, if we visit the GitHub repository, we can see that the enum System.Globalization.UnicodeCategory
(C # CLI) has been implemented. So why does not the compiler find: v?