1--TEST--
2ReflectionParameter::export() with incorrect second parameter
3--CREDITS--
4Stefan Koopmanschap <stefan@stefankoopmanschap.nl>
5--FILE--
6<?php
7function ReflectionParameterTest($test, $test2 = null) {
8	echo $test;
9}
10$reflect = new ReflectionFunction('ReflectionParameterTest');
11$params = $reflect->getParameters();
12foreach($params as $key => $value) {
13	ReflectionParameter::export('ReflectionParameterTest', 'incorrect_parameter');
14}
15--EXPECTF--
16
17Fatal error: Uncaught exception 'ReflectionException' with message 'The parameter specified by its name could not be found' in %s.php:%d
18Stack trace:
19#0 [internal function]: ReflectionParameter->__construct('ReflectionParam...', 'incorrect_param...')
20#1 %s.php(%d): ReflectionParameter::export('ReflectionParam...', 'incorrect_param...')
21#2 {main}
22  thrown in %s.php on line %d
23