Login Page - Create Account

Support Board


Date/Time: Wed, 17 Jul 2024 10:20:21 +0000



Post From: Notice: Study Exceptions in New Versions and Code Efficiency

[2020-05-22 04:06:44]
Sierra Chart Engineering - Posts: 104368
No not now in regards to post #7.

A safety problem was discovered involving these functions:
int& sc.GetPersistentIntFast(int32_t Index);
float& sc.GetPersistentFloatFast(int32_t Index);
double& sc.GetPersistentDoubleFast(int32_t Index);
SCDateTime& sc.GetPersistentSCDateTimeFast(int32_t Index);

There was not consideration to how when the internal vector is increased in size, that the memory addresses can change which means that as references are being made to the returned values, prior references made during the same call to the custom study function could change meaning the study function could be writing to an address which is no longer valid. And in that case the reference address would change on the next call into the study function.

This is now resolved in version 2109.

Effective with that version the valid range for the Index parameter is now 0 to 999.
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service:
Sierra Chart Teton Futures Order Routing
Date Time Of Last Edit: 2020-05-22 04:08:23