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 CalculateRelative($path,$pathRelative) | |
| { | |
| $parts1 = ($path.ToString()).Split("\") | |
| $parts2 = ($pathRelative.ToString()).Split("\") | |
| $prefixEqual = 0 | |
| $min = [Math]::Min($parts1.Length, $parts2.Length) | |
| $continue = $true | |
| while($prefixEqual -lt $min) | |
| { | |
| if ($parts1[$prefixEqual] -ne $parts2[$prefixEqual]) |
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 SCParser where | |
| import Text.Parsec | |
| import Text.Parsec.Token | |
| import Text.Parsec.Language | |
| data Expr = ScSymbol String | |
| | ScString String |
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 SCPPrint where | |
| import SCParser | |
| import Text.PrettyPrint.HughesPJ | |
| --toStringP :: Expr -> String | |
| toStringP (ScSymbol name) = text name | |
| toStringP (ScNumber num) = text $ show num | |
| toStringP (ScDouble num) = text $ show num |
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
| data Expr = ScSymbol String | |
| | ScString String | |
| | ScNumber Integer | |
| | ScDouble Double | |
| | ScCons Expr Expr | |
| | ScNil | |
| | ScBool Bool | |
| | ScQuote Expr | |
| deriving Show |
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 SCParser where | |
| import Text.Parsec | |
| import Text.Parsec.Token | |
| import Text.Parsec.Language | |
| data Expr = ScSymbol String | |
| | ScString String |
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 SCParser where | |
| import Text.Parsec | |
| import Text.Parsec.Token | |
| import Text.Parsec.Language | |
| data Expr = ScSymbol String | |
| | ScString String |
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 Experiment where | |
| import Text.Parsec | |
| import Text.Parsec.Token | |
| import Text.Parsec.Language | |
| data Expr = ScSymbol String | |
| | ScString String |
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 Experiment where | |
| import Text.Parsec | |
| import Text.Parsec.Token | |
| import Text.Parsec.Language | |
| data Expr = ScSymbol String | |
| | ScString String |
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 Experiment where | |
| import Text.Parsec | |
| import Text.Parsec.Token | |
| import Text.Parsec.Language | |
| data Expr = ScSymbol String | |
| | ScString String |
NewerOlder