This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| mouse.vusb.enable = "TRUE" | |
| mouse.vusb.useBasicMouse = "FALSE" | |
| mks.mouse.pixelScrollSensitivity = "1" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // This code will teach you how to write a simple recursive descent parser. | |
| // Corners will be cut, but by the end you will have the basis of most | |
| // programming languages out there: strings, numbers, identifiers, and | |
| // infix arithmetic expressions with precendence. | |
| // At under 100 lines, I promise it won't take long. Happy Hacking! | |
| // -- James Keane | |
| // | |
| // First the source code has to be tokenized, for the parser. | |
| // Let's do five tokens, and ignore whitespace: | |
| // 1. operators (+, -, *, etc.) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function tco(f) { | |
| let isin = false; | |
| return function() { | |
| if (isin) throw [this, arguments]; | |
| isin = true; | |
| let args = [this, arguments]; | |
| while(true) { | |
| try { | |
| const ret = f.apply(args[0], args[1]); | |
| isIn = false; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| border: no |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| border: no |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <link rel="import" href="../topeka-elements/theme.html"> | |
| <link rel="import" href="../topeka-elements/topeka-resources.html"> | |
| <link rel="import" href="../topeka-elements/topeka-app.html"> | |
| <polymer-element name="my-element"> | |
| <template> | |
| <style> | |
| :host { | |
| position: absolute; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <link rel="import" href="../polymer/polymer.html"> | |
| <polymer-element name="my-element"> | |
| <template> | |
| <style> | |
| :host { | |
| position: absolute; | |
| width: 100%; | |
| height: 100%; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (function(mod) { | |
| if (typeof exports == "object" && typeof module == "object") // CommonJS | |
| return mod(require("../lib/infer"), require("../lib/tern")); | |
| if (typeof define == "function" && define.amd) // AMD | |
| return define(["../lib/infer", "../lib/tern"], mod); | |
| mod(tern, tern); | |
| })(function(infer, tern) { | |
| "use strict"; | |
| var WG_TEMP_OBJ = 40; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from inspect import getfullargspec, getsourcelines | |
| type_map = { | |
| int: 'integer' | |
| } | |
| tmpl = """ | |
| CREATE FUNCTION {func_name} ({args}) | |
| RETURNS {return_t} | |
| AS $$ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import nails | |
| class IndexController(nails.Controller): | |
| def index(self, request): | |
| return "Hello World from controller!" | |
| def proof(self, request): | |
| return "Proof that routing is working" |
NewerOlder