# \#assignment

**URL:** https://discourse.julialang.org/tag/assignment/1686.md

[Latest](https://discourse.julialang.org/latest.md) · [Categories](https://discourse.julialang.org/categories.md) · [Tags](https://discourse.julialang.org/tags.md)

---

## [Keyword arguments not allowed on left-hand side of broadcast assignments?](https://discourse.julialang.org/t/keyword-arguments-not-allowed-on-left-hand-side-of-broadcast-assignments/133920)

<div class="topic-metadata">

**Author:** [@matthias314](https://discourse.julialang.org/u/matthias314)\
**Replies:** 1\
**Last updated:** [November 17, 2025, 3:18am UTC](https://discourse.julialang.org/t/keyword-arguments-not-allowed-on-left-hand-side-of-broadcast-assignments/133920 "2025-11-17T03:18:44Z")

</div>

Broadcasting with assignment works with a function call on the left-hand side. However, function calls with keyword arguments do not work for some reason: julia\> f(v; a = 0) = copy(v) f (generic function with 1 method) …

---

## [Can anyone improve this macro?](https://discourse.julialang.org/t/can-anyone-improve-this-macro/127359)

<div class="topic-metadata">

**Author:** [@GHTaarn](https://discourse.julialang.org/u/GHTaarn)\
**Replies:** 3\
**Last updated:** [March 26, 2025, 4:05am UTC](https://discourse.julialang.org/t/can-anyone-improve-this-macro/127359 "2025-03-26T04:05:37Z")

</div>

I have written the following macro: using Logging """ @no\_logging(code\_to\_execute) Execute \`code\_to\_execute\` sending all logging to the \[\`Logging.NullLogger\`\](@ref). """ macro no\_logging(code) return :( with\_…

---

## [Chained keyword assignment in function call leaks scope](https://discourse.julialang.org/t/chained-keyword-assignment-in-function-call-leaks-scope/126531)

<div class="topic-metadata">

**Author:** [@ncxst](https://discourse.julialang.org/u/ncxst)\
**Replies:** 1\
**Last updated:** [March 4, 2025, 3:29pm UTC](https://discourse.julialang.org/t/chained-keyword-assignment-in-function-call-leaks-scope/126531 "2025-03-04T15:29:08Z")

</div>

I tried to do a chained keyword assignment in a function call and got the following behavior julia\> function params(;kwargs...) for kw in kwargs println(kw) end end params (ge…

---

## [How to implement custom assignment with \`:=\` ? (for tinkering/learning purposes)](https://discourse.julialang.org/t/how-to-implement-custom-assignment-with-for-tinkering-learning-purposes/121467)

<div class="topic-metadata">

**Author:** [@Sevi](https://discourse.julialang.org/u/Sevi)\
**Replies:** 6\
**Last updated:** [October 21, 2024, 7:37am UTC](https://discourse.julialang.org/t/how-to-implement-custom-assignment-with-for-tinkering-learning-purposes/121467 "2024-10-21T07:37:35Z")

</div>

I stumbled across this post and realized I have no idea how I would actually implement := to mean something like “define/assign the variable if it is not already defined, otherwise throw an error”, so I’m looking for som…
