View source code
Display the source code in core/time.d from which this
page was generated on github.
Report a bug
If you spot a problem with this page, click here to create a
Bugzilla issue.
Improve this page
Quickly fork, edit online, and submit a pull request for this page.
Requires a signed-in GitHub account. This works well for small changes.
If you'd like to make larger changes you may want to consider using
local clone.
core.time.Duration.opOpAssign
- multiple declarations
Function Duration.opOpAssign
Adds, subtracts or calculates the modulo of two durations as well as
assigning the result to this Duration
.
ref Duration opOpAssign(string op, D)
(
in D rhs
) nothrow @nogc
if ((op == "+" || op == "-" || op == "%") && is(_Unqual!D == Duration) || (op == "+" || op == "-") && is(_Unqual!D == TickDuration));
The legal types of arithmetic for Duration
using this operator are
Duration | + | Duration | --> | Duration |
Duration | - | Duration | --> | Duration |
Duration | % | Duration | --> | Duration |
Duration | + | TickDuration | --> | Duration |
Duration | - | TickDuration | --> | Duration |
Parameters
Name | Description |
---|---|
rhs | The duration to add to or subtract from this Duration . |
Function Duration.opOpAssign
Multiplies/Divides the duration by an integer value as well as
assigning the result to this Duration
.
The legal types of arithmetic for Duration
using this operator
overload are
Duration | * | long | --> | Duration |
Duration | / | long | --> | Duration |
Parameters
Name | Description |
---|---|
value | The value to multiply/divide this Duration by. |
Authors
Jonathan M Davis and Kato Shoichi
License
Copyright © 1999-2018 by the D Language Foundation | Page generated by ddox.