Menu

- Learn
- Documentation
  - Language Reference
  - Library Reference
  - Command-line Reference
  - Feature Overview
  - Articles
- Downloads
- Packages
- Community
  - Blog
  - Orgs using D
  - Twitter
  - Forums
  - IRC
  - Community Discord
  - Wiki
  - GitHub
  - Issues
  - Get involved
  - Contributors
  - Foundation
  - Security Team
  - Donate
  - Sponsors
- Resources
  - Tour
  - Books
  - Tutorials
  - Tools
  - Editors
  - IDEs
  - run.dlang.io
  - Visual D
  - Acknowledgments
  - D Style
  - Glossary
  - Sitemap

Search
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 a local clone.

# rt.aApplyR

This code handles decoding UTF strings for foreach_reverse loops.
License:
Boost License 1.0.
Authors:
Walter Bright, Sean Kelly

Source rt/aApplyR.d

alias `dg_t` = int delegate(void* c);
  Delegate type corresponding to transformed loop body
  The parameter is a pointer to the current char, wchar or dchar
  Returns:
  non-zero when a break statement is hit
int `_aApplyRcd1`(in char[] `aa`, dg_t `dg`);
int `_aApplyRwd1`(in wchar[] `aa`, dg_t `dg`);
int `_aApplyRcw1`(in char[] `aa`, dg_t `dg`);
int `_aApplyRwc1`(in wchar[] `aa`, dg_t `dg`);
int `_aApplyRdc1`(in dchar[] `aa`, dg_t `dg`);
int `_aApplyRdw1`(in dchar[] `aa`, dg_t `dg`);
  Same as _aApplyXXX functions, but for foreach_reverse
  Parameters:

  char[] `aa` | input string
  dg_t `dg` | foreach body transformed into a delegate, similar to opApply

  Returns:
  non-zero when the loop was exited through a break
alias `dg2_t` = int delegate(void* i, void* c);
  Delegate type corresponding to transformed loop body
  Parameters are pointers to a size_t loop index, and the current char, wchar or dchar.
  Returns:
  non-zero when a break statement is hit
int `_aApplyRcd2`(in char[] `aa`, dg2_t `dg`);
int `_aApplyRwd2`(in wchar[] `aa`, dg2_t `dg`);
int `_aApplyRcw2`(in char[] `aa`, dg2_t `dg`);
int `_aApplyRwc2`(in wchar[] `aa`, dg2_t `dg`);
int `_aApplyRdc2`(in dchar[] `aa`, dg2_t `dg`);
int `_aApplyRdw2`(in dchar[] `aa`, dg2_t `dg`);
  Variants of aApplyRXXX that include a loop index.

Copyright © 1999-2023 by the D Language Foundation | Page generated by Ddoc on Sat Apr 1 13:09:58 2023