[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/session.php on line 574: sizeof(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/session.php on line 630: sizeof(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 494: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 113: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 5348: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3937)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 5348: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3937)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 5348: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3937)
Plum Geek Forum • error a function-definition is not allowed here bevore "{" token
Page 1 of 1

error a function-definition is not allowed here bevore "{" token

Posted: Fri Sep 25, 2015 8:33 pm
by Quinten1333
after playing for a while this error poped up

Arduino: 1.6.4 (Windows 8.1), Board:"Arduino Fio"

FunStuff.ino: In function 'void sensorcheck()':
FunStuff:29: error: a function-definition is not allowed here before '{' token
FunStuff:45: error: a function-definition is not allowed here before '{' token
FunStuff:55: error: a function-definition is not allowed here before '{' token
RingoHardware:948: error: expected '}' at end of input
a function-definition is not allowed here before '{' token

i've tried to delte the file funstuff but then it will just say
Arduino: 1.6.4 (Windows 8.1), Board:"Arduino Fio"

In file included from Navigation.ino:26:0:
A LOT OF LOCATION'S IN MY ARDUINO INSTALLATION FOLDER

Navigation:41: error: a function-definition is not allowed here before '{' token
Navigation:45: error: a function-definition is not allowed here before '{' token
RingoHardware:948: error: expected '}' at end of input
a function-definition is not allowed here before '{' token

so that doesn't work

I made about 5 sketches now and they all look (quite) the same(line follower).
also what i just edited in my sketch was the line detecting part wich is in all my sketches

hope someone knows the problem
sorry for bad english

Re: error a function-definition is not allowed here bevore "{" token

Posted: Fri Sep 25, 2015 8:39 pm
by Kevin
Quinten,

You want to leave all the files in place. It sounds as if there's a syntax error someplace. I don't think Arduino forces you to "define" a function before using it (this is a rule in C but I think Arduino overlooks this).

Check that you didn't miss a semicolon in your new function, and also make sure you didn't forget a closing curly brace }

If all else fails, open a clean copy of the Base Sketch, make your changes, then post it here so we can see it.

Good luck.

Re: error a function-definition is not allowed here bevore "{" token

Posted: Fri Sep 25, 2015 8:46 pm
by Quinten1333
I am so stupid

your right i forgot to use closing brackets in my new function

but how does that affect other tabs?


THANKS FOR RESPONDING SO FAST

Re: error a function-definition is not allowed here bevore "{" token

Posted: Fri Sep 25, 2015 11:02 pm
by Kevin

Re: error a function-definition is not allowed here bevore "{" token

Posted: Sat Sep 26, 2015 5:08 pm
by Quinten1333
okey thanks for your help