Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
davazp authored and tkers committed Apr 8, 2020
1 parent e9e4726 commit dfaedf2
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
5 changes: 5 additions & 0 deletions packages/liphe/components/Explorer/Expression.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { GenericSyntaxExplorer } from "../PPrinter";
import { BooleanExplorer } from "./Boolean";
import { useTypeNormalizer } from "./common";
import { FunctionExplorer } from "./Function";
import { FunctionCallExplorer } from "./FunctionCall";
import { NoneExplorer } from "./None";
import { NumberExplorer } from "./Number";
import { RecordExplorer } from "./Record";
Expand Down Expand Up @@ -35,6 +36,10 @@ export const ExpressionExplorer: React.FC<{
return (
<RecordExplorer record={{ ...expression, node: expression.node }} />
);
case "function-call":
return (
<FunctionCallExplorer call={{ ...expression, node: expression.node }} />
);
default: {
const normalizer = useTypeNormalizer();
return (
Expand Down
1 change: 1 addition & 0 deletions packages/liphe/components/PPrinter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ function DefinitionExplorer({
}

const Code = styled.pre`
display: inline-block;
background-color: white;
padding: 5px;
font-family: courier;
Expand Down
5 changes: 3 additions & 2 deletions packages/liphe/pages/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@ import { PageLayout } from "../components/PageLayout";

export default function Homepage() {
const [code, setCode] = useState(`
(lambda (f x)
(lambda (f g h x)
(print x)
(f)
(f 1 2 3 "foooooo")
(g 1 2 3 "foooooo" (h "foo" "bar") 10)
)`);

const [module, setModule] = useState<Delisp.Module<Typed>>();
Expand Down

0 comments on commit dfaedf2

Please sign in to comment.