From 110dd83852986d4acfd46d542e606bd85180e0e9 Mon Sep 17 00:00:00 2001 From: Marcelo Forets Date: Sun, 8 Sep 2019 11:49:55 -0300 Subject: [PATCH 1/3] Update guidelines.md --- docs/src/guidelines.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/docs/src/guidelines.md b/docs/src/guidelines.md index 5e1cc33..82d78bf 100644 --- a/docs/src/guidelines.md +++ b/docs/src/guidelines.md @@ -33,6 +33,9 @@ Depth = 3 "applied to a set of dimension $(dim(P))" ``` +!!! note + The 80 characters rule should not be enforced arbitrarily, but is rather a soft guideline. + - Use the full `function f() ... end` instead of `f() = ...`. However, the short form is preferable in constructors and aliases such as `×(X::LazySet, Y::LazySet) = CartesianProduct(X, Y)`. - Use the following conventions for type parameters: @@ -353,3 +356,9 @@ This example has an optional argument with default value. Inside a `@docs` block ```julia RecipesBase.apply_recipe(::Dict{Symbol,Any}, ::EmptySet{N}, ::N=zero(N)) where {N<:Real} ``` + +## Other style guides + +Below we list other Julia code style guides that we have found interesting. + +- [Yet Another Style Guide For Julia](https://github.com/jrevels/YASGuide) From de02272251c41f4b093a5193659197499e5b2d15 Mon Sep 17 00:00:00 2001 From: Marcelo Forets Date: Sun, 8 Sep 2019 12:02:30 -0300 Subject: [PATCH 2/3] Update guidelines.md --- docs/src/guidelines.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/src/guidelines.md b/docs/src/guidelines.md index 82d78bf..71b76cc 100644 --- a/docs/src/guidelines.md +++ b/docs/src/guidelines.md @@ -362,3 +362,5 @@ RecipesBase.apply_recipe(::Dict{Symbol,Any}, ::EmptySet{N}, ::N=zero(N)) where { Below we list other Julia code style guides that we have found interesting. - [Yet Another Style Guide For Julia](https://github.com/jrevels/YASGuide) +- [JuMP.jl style guide](http://www.juliaopt.org/JuMP.jl/dev/style/#Style-guide-and-design-principles-1) +- [Julia style guide](https://docs.julialang.org/en/v1.2/manual/style-guide/#Style-Guide-1) From da22ce6ca4589429a6eec29ac6f893a12f2b94dc Mon Sep 17 00:00:00 2001 From: Marcelo Forets Date: Sun, 8 Sep 2019 12:28:30 -0300 Subject: [PATCH 3/3] Update guidelines.md --- docs/src/guidelines.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/src/guidelines.md b/docs/src/guidelines.md index 71b76cc..e37d702 100644 --- a/docs/src/guidelines.md +++ b/docs/src/guidelines.md @@ -34,7 +34,7 @@ Depth = 3 ``` !!! note - The 80 characters rule should not be enforced arbitrarily, but is rather a soft guideline. + The 80 characters rule should not be enforced in all cases, but is rather a soft guideline. - Use the full `function f() ... end` instead of `f() = ...`. However, the short form is preferable in constructors and aliases such as `×(X::LazySet, Y::LazySet) = CartesianProduct(X, Y)`.