source: src/router/php7/ext/opcache/tests/bug73402.phpt @ 31874

Last change on this file since 31874 was 31874, checked in by brainslayer, 3 months ago

update php

File size: 430 bytes
Line 
1--TEST--
2Bug #73402 (Opcache segfault when using class constant to call a method)
3--INI--
4opcache.enable=1
5opcache.enable_cli=1
6--SKIPIF--
7<?php require_once('skipif.inc'); ?>
8--FILE--
9<?php
10class Logger {
11        public function info($msg) {
12                echo $msg;
13        }
14}
15
16class B
17{
18        const LOG_LEVEL = 'Info';
19        public function test()
20        {
21                $logger = new \Logger();
22                $logger->{self::LOG_LEVEL}('test');
23        }
24}
25
26$b = new B;
27$b->test();
28--EXPECT--
29test
Note: See TracBrowser for help on using the repository browser.