-
-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
74dfc7a
commit dafc500
Showing
42 changed files
with
6,420 additions
and
11 deletions.
There are no files selected for viewing
This file contains 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 file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,14 @@ | ||
/// Configuration used by the formatter | ||
#[derive(Clone)] | ||
pub struct Config {} | ||
pub struct Config { | ||
/// Indentation to use, e.g. `" "` (two spaces). | ||
pub indentation: String, | ||
} | ||
|
||
use std::default::Default; | ||
|
||
impl Default for Config { | ||
fn default() -> Self { | ||
Self {} | ||
Self { indentation: String::from(" ") } | ||
} | ||
} |
This file contains 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 file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,114 @@ | ||
[ | ||
(a | ||
b) | ||
( | ||
(a b) | ||
(a b) | ||
(a | ||
/* | ||
b | ||
*/ | ||
c) | ||
( | ||
/* | ||
a | ||
*/ | ||
b | ||
/* | ||
c | ||
*/ | ||
d | ||
/* | ||
e | ||
*/ | ||
) | ||
) | ||
'' | ||
otherModules=${ | ||
pkgs.writeText "other-modules.json" | ||
(l.toJSON | ||
(l.mapAttrs | ||
(pname: subOutputs: let | ||
pkg = | ||
subOutputs.packages."${pname}".overrideAttrs (old: { | ||
buildScript = "true"; | ||
installMethod = "copy"; | ||
}); | ||
in "${pkg}/lib/node_modules/${pname}/node_modules") | ||
outputs.subPackages)) | ||
} | ||
'' | ||
{ | ||
name1 = | ||
function | ||
arg | ||
{asdf = 1;}; | ||
|
||
name2 = | ||
function | ||
arg | ||
{asdf = 1;} | ||
argument; | ||
|
||
name3 = | ||
function | ||
arg | ||
{asdf = 1;} | ||
{qwer = 12345;} | ||
argument; | ||
} | ||
{ | ||
name1 = | ||
function arg { | ||
asdf = 1; | ||
}; | ||
|
||
name2 = | ||
function arg { | ||
asdf = 1; | ||
} | ||
argument; | ||
|
||
name3 = | ||
function arg { | ||
asdf = 1; | ||
} { | ||
qwer = 12345; | ||
} | ||
argument; | ||
} | ||
{ | ||
name4 = | ||
function | ||
arg | ||
{asdf = 1;} | ||
{ | ||
qwer = 12345; | ||
qwer2 = 54321; | ||
} | ||
argument; | ||
} | ||
{ | ||
option1 = | ||
function arg {asdf = 1;} { | ||
qwer = 12345; | ||
qwer2 = 54321; | ||
} | ||
lastArg; | ||
|
||
option2 = | ||
function arg {asdf = 1;} { | ||
qwer = 12345; | ||
qwer2 = 54321; | ||
} | ||
lastArg; | ||
|
||
option3 = | ||
function arg {asdf = 1;} | ||
{ | ||
qwer = 12345; | ||
qwer2 = 54321; | ||
} | ||
lastArg; | ||
} | ||
] |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
[ | ||
(assert b; e) | ||
(assert b; | ||
/* | ||
d | ||
*/ | ||
e) | ||
(assert b; e) | ||
(assert b; | ||
/* | ||
d | ||
*/ | ||
e) | ||
(assert | ||
/* | ||
a | ||
*/ | ||
b; e) | ||
(assert | ||
/* | ||
a | ||
*/ | ||
b; | ||
/* | ||
d | ||
*/ | ||
e) | ||
(assert | ||
/* | ||
a | ||
*/ | ||
b; e) | ||
(assert | ||
/* | ||
a | ||
*/ | ||
b; | ||
/* | ||
d | ||
*/ | ||
e) | ||
(assert b; cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc) | ||
(assert b; cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc) | ||
] |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,138 @@ | ||
[ | ||
{} | ||
{ | ||
/* | ||
a | ||
*/ | ||
} | ||
{a = 1;} | ||
{ | ||
a = 1; | ||
} | ||
|
||
{b = 1;} | ||
{ | ||
b = 1; | ||
/* | ||
c | ||
*/ | ||
} | ||
{ | ||
/* | ||
a | ||
*/ | ||
b = 1; | ||
} | ||
{ | ||
/* | ||
a | ||
*/ | ||
b = 1; | ||
/* | ||
c | ||
*/ | ||
} | ||
|
||
rec {c = 1;} | ||
rec { | ||
c = 1; | ||
/* | ||
d | ||
*/ | ||
} | ||
rec { | ||
/* | ||
b | ||
*/ | ||
c = 1; | ||
} | ||
rec { | ||
/* | ||
b | ||
*/ | ||
c = 1; | ||
/* | ||
d | ||
*/ | ||
} | ||
rec | ||
/* | ||
a | ||
*/ | ||
{ | ||
c = 1; | ||
} | ||
rec | ||
/* | ||
a | ||
*/ | ||
{ | ||
c = 1; | ||
/* | ||
d | ||
*/ | ||
} | ||
rec | ||
/* | ||
a | ||
*/ | ||
{ | ||
/* | ||
b | ||
*/ | ||
c = 1; | ||
} | ||
rec | ||
/* | ||
a | ||
*/ | ||
{ | ||
/* | ||
b | ||
*/ | ||
c = 1; | ||
/* | ||
d | ||
*/ | ||
} | ||
|
||
{ | ||
a = rec { | ||
a = { | ||
a = rec { | ||
a = { | ||
a = rec {a = {a = rec {a = {a = rec {a = {};};};};};}; | ||
}; | ||
}; | ||
}; | ||
}; | ||
} | ||
|
||
rec { | ||
c = 1; | ||
|
||
e = 1; | ||
} | ||
|
||
rec | ||
/* | ||
a | ||
*/ | ||
{ | ||
/* | ||
b | ||
*/ | ||
|
||
c = 1; | ||
|
||
/* | ||
d | ||
*/ | ||
|
||
e = 1; | ||
|
||
/* | ||
f | ||
*/ | ||
} | ||
] |
Oops, something went wrong.