<commit_before>{-# LANGUAGE PatternGuards #-}
-- | Module to generate Javascript from a ModGuts structure
module CodeGen.Javascript.Generate (generate) where
import GhcPlugins as P
import Class
import ForeignCall
import qualified Data.Map as M
import qualified Data.Set as S
import Data.List (foldl')

import CodeGen.Javascript.Monad
import CodeGen.Javascript.AST as AST hiding (unique,name,deps,code)
import qualified CodeGen.Javascript.AST as AST (name, deps, code)
import Bag
import CodeGen.Javascript.PrimOps
import CodeGen.Javascript.PrintJS (prettyJS, pseudo)

import Debug.Trace

-- | Turn a pile of Core into our intermediate JS AST.<commit_msg>Remove leftover debug imports.<commit_after>{-# LANGUAGE PatternGuards #-}
-- | Module to generate Javascript from a ModGuts structure
module CodeGen.Javascript.Generate (generate) where
import GhcPlugins as P
import ForeignCall
import qualified Data.Map as M
import qualified Data.Set as S
import Data.List (foldl')

import CodeGen.Javascript.Monad
import CodeGen.Javascript.AST as AST hiding (unique,name,deps,code)
import qualified CodeGen.Javascript.AST as AST (name, deps, code)
import Bag
import CodeGen.Javascript.PrimOps
import CodeGen.Javascript.PrintJS (prettyJS, pseudo)

-- | Turn a pile of Core into our intermediate JS AST.
{'fraction_non_alphanumeric': 0.07596899224806201, 'fraction_numerical': 0.0, 'mean_word_length': 5.359605911330049, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6940808', 'n_tokens_mistral': 399, 'n_tokens_neox': 372, 'n_words': 142}