summaryrefslogtreecommitdiff
path: root/source/Syntax/Lexicon.hs
diff options
context:
space:
mode:
authoradelon <22380201+adelon@users.noreply.github.com>2026-07-30 23:13:36 +0200
committeradelon <22380201+adelon@users.noreply.github.com>2026-07-30 23:13:36 +0200
commit0f0b966d958464f08b6efa39f9eee38d96509c19 (patch)
treeda90573ab89315d279bfd18d9ee74d38d7328289 /source/Syntax/Lexicon.hs
parent36feebc1722cdfeeb15601fe73c9dd9bc0e69bf3 (diff)
Build module-local syntax interfaces
Diffstat (limited to 'source/Syntax/Lexicon.hs')
-rw-r--r--source/Syntax/Lexicon.hs13
1 files changed, 11 insertions, 2 deletions
diff --git a/source/Syntax/Lexicon.hs b/source/Syntax/Lexicon.hs
index 31af3a9..4e95da9 100644
--- a/source/Syntax/Lexicon.hs
+++ b/source/Syntax/Lexicon.hs
@@ -90,8 +90,14 @@ lexiconPatterns Lexicon{..} =
[ Set.fromList (concatMap Map.keys (toList lexiconMixfixTable))
, Set.fromList (lexicalItemPattern <$> lexiconAdjLs)
, Set.fromList (lexicalItemPattern <$> lexiconAdjRs)
- , Set.fromList (sg . lexicalItemSgPlPattern <$> lexiconVerbs)
- , Set.fromList (sg . lexicalItemSgPlPattern <$> lexiconNouns)
+ , Set.fromList
+ (concatMap
+ (bothPatterns . lexicalItemSgPlPattern)
+ lexiconVerbs)
+ , Set.fromList
+ (concatMap
+ (bothPatterns . lexicalItemSgPlPattern)
+ lexiconNouns)
, Set.fromList (sg . lexicalItemSgPlPattern <$> lexiconStructNouns)
, Set.fromList (sg . lexicalItemSgPlPattern <$> lexiconFuns)
, Set.fromList (relationSymbolPattern <$> lexiconRelationSymbols)
@@ -99,6 +105,9 @@ lexiconPatterns Lexicon{..} =
, Set.fromList
(prefixPredicatePattern . fst <$> lexiconPrefixPredicates)
]
+ where
+ bothPatterns patterns =
+ [sg patterns, pl patterns]
prefixPredicatePattern :: PrefixPredicate -> Pattern
prefixPredicatePattern (PrefixPredicate command _arity) =