microsoft / microsoft/Power-Fx

Symbols: Composed symbol tables don't do FunctionNames

Open
#1,999 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
3.4k
Forks
358
Avg merge
10h 34m
Merged PRs (30d)
3

Description

ComposedReadOnlySymbolTable properly handles function lookup, but does not handle function names.
This should probably be overridden.

https://github.com/microsoft/Power-Fx/blob/fe0270d3f709e1c308466101467d20587db91aae/src/libraries/Microsoft.PowerFx.Core/Public/Config/ReadOnlySymbolTable.cs#L293

public IEnumerable<string> FunctionNames => _functions.FunctionNames;

It's also suspect that ReadOnlySymbolTable has mutable state like:

internal readonly Dictionary<string, NameLookupInfo> _variables = new Dictionary<string, NameLookupInfo>();
private protected readonly TexlFunctionSet _functions = new TexlFunctionSet();

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with src/libraries/Microsoft.PowerFx.Core/Public/Config/ReadOnlySymbolTable.cs at the FunctionNames property, then inspect ComposedReadOnlySymbolTable and how it handles function lookup. Confirm that FunctionNames reflects the composed tables, and add or update coverage for the expected names if the relevant tests can be located.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
compilers
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.