Closed EraYaN closed 8 years ago
If I remove all = 0
parts from the functions in IAlgorithm.h so it looks like this:
#pragma once
#ifndef IALGORITHM_H
#define IALGORITHM_H
class IAlgorithm {
public:
virtual ~IAlgorithm() {};
virtual void Tick(float MeasuredPower) {};
virtual float GetDuty(void) {};
virtual float GetCurrent(void) {};
virtual void ResetTo(float ResetCurrent, float ResetDuty) {};
};
#endif
It all links fine. Although to be able to use abstract classes would be a nice thing. All other compilers (for x86 that is) work fine.
Hi @EraYaN ! Please re-test your project with the latest PlatformIO from the develop branch. Thanks!
Thank you for the fix. I updated using pip to 2.9.4. Because it is easier and I saw the version bump. (And I'm lazy ;))
The project compiles fine now. I haven't had the chance to actually try the generated code (no hardware). Will do so Wednesday.
Configuration
Operating system: Win 10 x64
PlatformIO Version (
platformio --version
): 2.9.1Description of problem
When building for LPC1768 target and when your code contains abstract classes (with pure virtual members), the following error occur (PlatformIO CLI, or Visual Studio)
Steps to Reproduce
platformio run
in Test/or
Actual Results
Expected Results
A properly compiled bin.
The mbed online compiler has no issues: http://i.imgur.com/0Tu2vWM.png MSVC has no problems compiling this for x64.
If problems with PlatformIO Build System:
The content of
platformio.ini
:Source file to reproduce issue: (Headers and other files are here: https://erayan.com/shared/Test.zip)
Some people suggested it had to do with specs files, but that goes way over my head.