# Allow docstring on the right of string fields

**URL:** <https://discourse.julialang.org/t/allow-docstring-on-the-right-of-string-fields/125786>\
**Category:** Internals & Design\
**Created:** [February 11, 2025, 12:30pm UTC](https://discourse.julialang.org/t/allow-docstring-on-the-right-of-string-fields/125786 "2025-02-11T12:30:05Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Post date:** [February 11, 2025, 12:30pm UTC](https://discourse.julialang.org/t/allow-docstring-on-the-right-of-string-fields/125786/1 "2025-02-11T12:30:06Z")

</div>

In the era of super-wide screens, would allowing docstring on the right of struct fields be breaking ?

Compare this:

 ![image](https://global.discourse-cdn.com/julialang/original/3X/3/2/322de9ac8ab8b73d3762d15469c010ad12c7a5ff.png)

To this:

 ![image](https://global.discourse-cdn.com/julialang/original/3X/6/2/62bd7ee7afb75721ab4dc9f265bffb26bfa6240b.png)

---

<div class="post-metadata">

**Author:** ![GHTaarn](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ghtaarn/32/216007_2.png) [@GHTaarn](https://discourse.julialang.org/u/GHTaarn)\
**Post date:** [February 11, 2025, 2:01pm UTC](https://discourse.julialang.org/t/allow-docstring-on-the-right-of-string-fields/125786/2 "2025-02-11T14:01:43Z")

</div>

In my REPL, even the first alternative does not show in the docstring, should it?

---

<div class="post-metadata">

**Author:** ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Post date:** [February 11, 2025, 2:05pm UTC](https://discourse.julialang.org/t/allow-docstring-on-the-right-of-string-fields/125786/3 "2025-02-11T14:05:50Z")

</div>

I don’t know on the REPL… the information should be “saved” as a docstring, then you can use packages like `DocStringExtensions` that extract this information and show it in the REPL (using `?StructName` ) or in the rendered output of `Documenter.jl`

You made now me thinking that perhaps the fact to consider it as a docstring could be a contribution of the `DocStringExtensions` package… any-how, replacing the comment on the right (second screenshot) with a string generates a parsing error…

---

<div class="post-metadata">

**Author:** ![Datseris](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/datseris/32/13406_2.png) [@Datseris](https://discourse.julialang.org/u/Datseris)\
**Post date:** [February 11, 2025, 3:08pm UTC](https://discourse.julialang.org/t/allow-docstring-on-the-right-of-string-fields/125786/4 "2025-02-11T15:08:31Z")

</div>

as an ultra-wide screen fanboy myself I also would like such an option! Coincidentally, defining variables in ModelingToolkit does allow for such nice display:

```julia
ctbbl_parameters = @parameters begin
    (d = 0.0012), [bounds = (7.9e-4, 0.0021), description = "aerodynamic bulk drag/transfer coefficient"]
    (D = 3e-6), [description = "large scale divergence, 1/s"]
    (CO2 = 400.0), [description = "CO2 concentration, ppm"]
    (RH₊ = 0.2), [description = "relative humidity above boundary layer"]
    (ECS_CO2 = 3.0), [description = "tropospheric warming per doubling of CO2 (global warming), K"]
    (δ_Δ₊T = 5.0), [description = "prescribed variability in temperature inversion (difference), K"]
    (T₊_0 = 287.5), [description = "prescribed temperature above inversion without CO2 or cloud effects, K"]
    (T_FTR_0 = 293.0), [description = "prescribed temperature emission of free troposphere without CO2 effects, K"]
    (δ_FTR = 0.0), [description = "Environmental variability of T_FTR, K"]

```
