Skip to content

Commit 684bd83

Browse files
committed
Auto-generated commit
1 parent 8751dce commit 684bd83

File tree

7 files changed

+25
-22
lines changed

7 files changed

+25
-22
lines changed

CHANGELOG.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
55
<section class="release" id="unreleased">
66

7-
## Unreleased (2025-05-18)
7+
## Unreleased (2025-05-21)
88

99
<section class="features">
1010

@@ -23,6 +23,8 @@
2323

2424
<details>
2525

26+
- [`c76fda3`](https://github.com/stdlib-js/stdlib/commit/c76fda338a38ced6292591153522858817f47c11) - **bench:** update Makefiles to follow current project conventions _(by Karan Anand)_
27+
- [`1cfea57`](https://github.com/stdlib-js/stdlib/commit/1cfea575fc941a1e3e4f2c492f64b339906880a5) - **refactor:** remove `typedef` from `STDLIB_BASE_HEAVISIDEF_CONTINUITY` enum definition _(by Karan Anand)_
2628
- [`9b48575`](https://github.com/stdlib-js/stdlib/commit/9b48575a2670874e64b076f79ebd9989b43db5a0) - **feat:** add C implementation for `math/base/special/heavisidef` [(#7022)](https://github.com/stdlib-js/stdlib/pull/7022) _(by Karan Anand, stdlib-bot)_
2729
- [`0395909`](https://github.com/stdlib-js/stdlib/commit/03959095fb9ffbe34ca9603b27c5204ce82d8c89) - **docs:** replace manual `for` loop in examples [(#6638)](https://github.com/stdlib-js/stdlib/pull/6638) _(by Harsh)_
2830
- [`630ddb7`](https://github.com/stdlib-js/stdlib/commit/630ddb777824b5f6e501fda6dadf4ce41dccb964) - **test:** replace equal with strictEqual _(by Karan Anand)_

CONTRIBUTORS

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,7 @@ Ryan Seal <splrk@users.noreply.github.com>
146146
Rylan Yang <137365285+rylany27@users.noreply.github.com>
147147
SAHIL KUMAR <168997976+sahilk45@users.noreply.github.com>
148148
SHIVAM YADAV <120725381+Shivam-1827@users.noreply.github.com>
149+
Sachin Raj <120590207+schnrj@users.noreply.github.com>
149150
Sahil Goyal <87982509+sahil20021008@users.noreply.github.com>
150151
Sai Avinash <120403424+nasarobot@users.noreply.github.com>
151152
Sai Srikar Dumpeti <80447788+the-r3aper7@users.noreply.github.com>
@@ -170,6 +171,7 @@ Tanishq Ahuja <68651083+TheGEN1U5@users.noreply.github.com>
170171
Tirtadwipa Manunggal <tirtadwipa.manunggal@gmail.com>
171172
Tudor Pagu <104032457+tudor-pagu@users.noreply.github.com>
172173
Tufailahmed Bargir <142114244+Tufailahmed-Bargir@users.noreply.github.com>
174+
Uday Kakade <141299403+udaykakade25@users.noreply.github.com>
173175
Utkarsh <http://utkarsh11105@gmail.com>
174176
Utkarsh Raj <rajutkarsh2505@gmail.com>
175177
UtkershBasnet <119008923+UtkershBasnet@users.noreply.github.com>

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ y = stdlib_base_heavisidef( 0.0f, STDLIB_BASE_HEAVISIDEF_CONTINUITY_LEFT_CONTINU
238238
The function accepts the following arguments:
239239

240240
- **x**: `[in] float` input value.
241-
- **continuity**: `[in] STDLIB_BASE_HEAVISIDEF_CONTINUITY` continuity option.
241+
- **continuity**: `[in] enum STDLIB_BASE_HEAVISIDEF_CONTINUITY` continuity option.
242242

243243
The `continuity` parameter may be one of the following values:
244244

@@ -250,7 +250,7 @@ The `continuity` parameter may be one of the following values:
250250
If provided a `continuity` argument which is not one of the enumeration constants listed above, the function returns `NaN` for `x == 0`, behaving like the discontinuous case.
251251

252252
```c
253-
float stdlib_base_heavisidef( const float x, const STDLIB_BASE_HEAVISIDEF_CONTINUITY continuity );
253+
float stdlib_base_heavisidef( const float x, const enum STDLIB_BASE_HEAVISIDEF_CONTINUITY continuity );
254254
```
255255
256256
</section>

benchmark/c/Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
# limitations under the License.
1717
#/
1818

19-
2019
# VARIABLES #
2120

2221
ifndef VERBOSE

benchmark/c/native/Makefile

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -88,15 +88,15 @@ c_targets := benchmark.out
8888
# RULES #
8989

9090
#/
91-
# Compiles source files.
91+
# Compiles C source files.
9292
#
93-
# @param {string} [C_COMPILER] - C compiler (e.g., `gcc`)
94-
# @param {string} [CFLAGS] - C compiler options
95-
# @param {(string|void)} [fPIC] - compiler flag determining whether to generate position independent code (e.g., `-fPIC`)
96-
# @param {string} [INCLUDE] - list of includes (e.g., `-I /foo/bar -I /beep/boop/include`)
97-
# @param {string} [SOURCE_FILES] - list of source files
93+
# @param {string} SOURCE_FILES - list of C source files
94+
# @param {string} [INCLUDE] - list of includes (e.g., `-I /foo/bar -I /beep/boop`)
95+
# @param {string} [LIBRARIES] - list of libraries (e.g., `-lpthread -lblas`)
9896
# @param {string} [LIBPATH] - list of library paths (e.g., `-L /foo/bar -L /beep/boop`)
99-
# @param {string} [LIBRARIES] - list of libraries (e.g., `-lopenblas -lpthread`)
97+
# @param {string} [C_COMPILER] - C compiler
98+
# @param {string} [CFLAGS] - C compiler flags
99+
# @param {(string|void)} [fPIC] - compiler flag indicating whether to generate position independent code
100100
#
101101
# @example
102102
# make
@@ -112,13 +112,13 @@ all: $(c_targets)
112112
# Compiles C source files.
113113
#
114114
# @private
115-
# @param {string} CC - C compiler (e.g., `gcc`)
116-
# @param {string} CFLAGS - C compiler options
117-
# @param {(string|void)} fPIC - compiler flag determining whether to generate position independent code (e.g., `-fPIC`)
118-
# @param {string} INCLUDE - list of includes (e.g., `-I /foo/bar`)
119-
# @param {string} SOURCE_FILES - list of source files
120-
# @param {string} LIBPATH - list of library paths (e.g., `-L /foo/bar`)
121-
# @param {string} LIBRARIES - list of libraries (e.g., `-lopenblas`)
115+
# @param {string} SOURCE_FILES - list of C source files
116+
# @param {(string|void)} INCLUDE - list of includes (e.g., `-I /foo/bar -I /beep/boop`)
117+
# @param {(string|void)} LIBRARIES - list of libraries (e.g., `-lpthread -lblas`)
118+
# @param {(string|void)} LIBPATH - list of library paths (e.g., `-L /foo/bar -L /beep/boop`)
119+
# @param {string} CC - C compiler
120+
# @param {string} CFLAGS - C compiler flags
121+
# @param {(string|void)} fPIC - compiler flag indicating whether to generate position independent code
122122
#/
123123
$(c_targets): %.out: %.c
124124
$(QUIET) $(CC) $(CFLAGS) $(fPIC) $(INCLUDE) -o $@ $(SOURCE_FILES) $< $(LIBPATH) -lm $(LIBRARIES)

include/stdlib/math/base/special/heavisidef.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ extern "C" {
2727
#endif
2828

2929
// Enumeration of function continuity:
30-
typedef enum STDLIB_BASE_HEAVISIDEF_CONTINUITY {
30+
enum STDLIB_BASE_HEAVISIDEF_CONTINUITY {
3131
// Half-maximum:
3232
STDLIB_BASE_HEAVISIDEF_CONTINUITY_HALF_MAXIMUM = 0,
3333

@@ -39,12 +39,12 @@ typedef enum STDLIB_BASE_HEAVISIDEF_CONTINUITY {
3939

4040
// Discontinuous:
4141
STDLIB_BASE_HEAVISIDEF_CONTINUITY_DISCONTINUOUS = 3
42-
} STDLIB_BASE_HEAVISIDEF_CONTINUITY;
42+
};
4343

4444
/**
4545
* Evaluates the Heaviside function for a single-precision floating-point number.
4646
*/
47-
float stdlib_base_heavisidef( const float x, const STDLIB_BASE_HEAVISIDEF_CONTINUITY continuity );
47+
float stdlib_base_heavisidef( const float x, const enum STDLIB_BASE_HEAVISIDEF_CONTINUITY continuity );
4848

4949
#ifdef __cplusplus
5050
}

src/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
* float y = stdlib_base_heavisidef( 0.0f, STDLIB_BASE_HEAVISIDEF_CONTINUITY_HALF_MAXIMUM );
3131
* // returns 0.5f
3232
*/
33-
float stdlib_base_heavisidef( const float x, const STDLIB_BASE_HEAVISIDEF_CONTINUITY continuity ) {
33+
float stdlib_base_heavisidef( const float x, const enum STDLIB_BASE_HEAVISIDEF_CONTINUITY continuity ) {
3434
if ( stdlib_base_is_nanf( x ) ) {
3535
return 0.0f / 0.0f; // NaN
3636
}

0 commit comments

Comments
 (0)