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 is a showcase on how boolean unification can be used to type check the weird parts of Javascript. | |
| */ | |
| /* | |
| Each boolean paramater is a flag for a possible value for a Javascript builtin | |
| For example: | |
| `Value [false, true, false, false, false, false false, false]` must be a string | |
| `Value [false, true, true, false, false, false false, true]` must be a string, a number, or null | |
| */ |
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
| module Combinator where | |
| {- | |
| mnemonics: | |
| pos : position | |
| str : string | |
| err : error | |
| -} | |
| import Control.Applicative (Alternative, empty, many, (<|>)) |
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
| #include <cstddef> | |
| #include <string> | |
| #include <type_traits> | |
| template <class Object> class Ref; | |
| class Object { | |
| template <class> friend class Ref; | |
| size_t reference; |
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
| /* Copyright (C) Freddy A Cubas "superstar64" | |
| Boost Software License - Version 1.0 - August 17th, 2003 | |
| Permission is hereby granted, free of charge, to any person or organization | |
| obtaining a copy of the software and accompanying documentation covered by | |
| this license (the "Software") to use, reproduce, display, distribute, | |
| execute, and transmit the Software, and to prepare derivative works of the | |
| Software, and to permit third-parties to whom the Software is furnished to | |
| do so, all subject to the following: |
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
| #include <assert.h> | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <string.h> | |
| #include <sys/mman.h> | |
| typedef struct list_data (*list)(); | |
| struct list_data { | |
| long head; |
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
| /* Copyright (C) Freddy A Cubas "superstar64" | |
| Boost Software License - Version 1.0 - August 17th, 2003 | |
| Permission is hereby granted, free of charge, to any person or organization | |
| obtaining a copy of the software and accompanying documentation covered by | |
| this license (the "Software") to use, reproduce, display, distribute, | |
| execute, and transmit the Software, and to prepare derivative works of the | |
| Software, and to permit third-parties to whom the Software is furnished to | |
| do so, all subject to the following: |
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 java.util.function.Function; | |
| // straight forward port of freer monads to java | |
| // see http://okmij.org/ftp/Computation/free-monad.html | |
| // lightweight higher kinded polymorphism | |
| // see http://ocamllabs.io/higher/lightweight-higher-kinded-polymorphism.pdf | |
| interface App<F,A> {} |
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
| /* Copyright Freddy A Cubas "superstar64" | |
| Boost Software License - Version 1.0 - August 17th, 2003 | |
| Permission is hereby granted, free of charge, to any person or organization | |
| obtaining a copy of the software and accompanying documentation covered by | |
| this license (the "Software") to use, reproduce, display, distribute, | |
| execute, and transmit the Software, and to prepare derivative works of the | |
| Software, and to permit third-parties to whom the Software is furnished to | |
| do so, all subject to the following: |
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
| /* Copyright Freddy A Cubas "Superstar64" | |
| Boost Software License - Version 1.0 - August 17th, 2003 | |
| Permission is hereby granted, free of charge, to any person or organization | |
| obtaining a copy of the software and accompanying documentation covered by | |
| this license (the "Software") to use, reproduce, display, distribute, | |
| execute, and transmit the Software, and to prepare derivative works of the | |
| Software, and to permit third-parties to whom the Software is furnished to | |
| do so, all subject to the following: |
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
| /* Copyright (C) Freddy A Cubas "Superstar64" | |
| Boost Software License - Version 1.0 - August 17th, 2003 | |
| Permission is hereby granted, free of charge, to any person or organization | |
| obtaining a copy of the software and accompanying documentation covered by | |
| this license (the "Software") to use, reproduce, display, distribute, | |
| execute, and transmit the Software, and to prepare derivative works of the | |
| Software, and to permit third-parties to whom the Software is furnished to | |
| do so, all subject to the following: |
NewerOlder